package com.example.demo.mapper;

import com.example.demo.domain.Contacts;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Insert;

/**
* @author 86187
* @description 针对表【contacts】的数据库操作Mapper
* @createDate 2025-06-18 16:47:33
* @Entity com.example.demo.domain.Contacts
*/
public interface ContactsMapper extends BaseMapper<Contacts> {

    /**
     * 插入联系人信息到数据库
     *
     * @param Contacts 联系人对象
     */
    @Insert("INSERT INTO contacts (user_id, contact_name, relation_status, last_message, last_message_time) " +
            "VALUES (#{userId}, #{contactName}, #{relationStatus}, #{lastMessage}, #{lastMessageTime})")
    int insert(Contacts Contacts);
}




